package cfsmon.common;

/**
 * A parameter consist of a type and an identifier
 * @author Alexander Gebhardt
 */
public class Parameter implements Comparable<Parameter> {
	
	public final String type;
	public final String name;
	
	public Parameter(String type, String name) {
		super();
		this.type = type;
		this.name = name;
	}
	
	@Override
	public String toString(){
		return type + " " + name;
	}

	@Override
	public int compareTo(Parameter o) {
		int r = name.compareTo(o.name);
		if (r != 0) return r;
		r = type.compareTo(o.type);
		return r;
	}
	
}
